﻿//BUG 45625 sunfx 2009年5月11日17:07:39
//屏蔽退格键
function cancelBackspace() {
    var e = window.event;
    if (e && e.keyCode == 8) {
        var elem = e.srcElement;
        if (elem &&
                        (elem.tagName.toUpperCase() == "TEXTAREA"
                            || (elem.tagName.toUpperCase() == "INPUT" && elem.type.toUpperCase() == "TEXT")) && elem.isDisabled == false && elem.readOnly != true) {
            return true;
        }
        return false;
    }
}
setTimeout(bindCancelBackspace, 100);
function bindCancelBackspace() {
    if (document.readyState != "complete") {
        setTimeout(bindCancelBackspace, 100);
        return;
    }
    document.attachEvent("onkeydown", cancelBackspace);
}
//BUG 45625 END